package com.vrv.vap.baseline.service.impl;

import com.vrv.vap.baseline.config.ExcelTemplateConfig;
import com.vrv.vap.baseline.entity.AssetTypeSno;
import com.vrv.vap.baseline.mapper.AssetTypeSnoMapper;
import com.vrv.vap.baseline.service.AbstractExcelExportService;
import com.vrv.vap.baseline.util.FileOperationUtil;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.io.IOException;
import java.util.List;

@Service
public class AssetTypeSnoExportService extends AbstractExcelExportService<AssetTypeSno> {
    @Autowired
    private AssetTypeSnoMapper assetTypeSnoMapper;

    public AssetTypeSnoExportService(FileOperationUtil fileOperationUtil, ExcelTemplateConfig excelTemplateConfig) {
        super(fileOperationUtil, excelTemplateConfig, "asset_type_sno");
    }

    @Override
    protected List<AssetTypeSno> getAllData() {
        return assetTypeSnoMapper.selectAll();
    }

    @Override
    protected void processData(List<AssetTypeSno> dataList, String format) throws IOException {
        // 如果需要对数据进行处理，可以在这里实现
    }

    @Override
    protected Class<AssetTypeSno> getEntityClass() {
        return AssetTypeSno.class;
    }
}